<template>
	
		<view style="display: flex;"
		:style="{
			'width': nodeModel.widthForFlex1+'rpx',
			'height': '250'+'rpx',
			'flex-direction': nodeModel.flex_directionForFlex1,
			'align-items': nodeModel.align_itemsForFlex1,
			'background': nodeModel.backgroundForFlex1,
			'marginTop': nodeModel.marginTopForFlex1+'rpx',
			'marginLeft': nodeModel.marginLeftForFlex1+'rpx',
			'paddingTop': nodeModel.paddingTopForFlex1+'rpx',
			'paddingBottom': nodeModel.paddingBottomForFlex1+'rpx',
			'paddingLeft': nodeModel.paddingLeftForFlex1+'rpx',
		}">
			<view>
				<image :style="{
					'width': nodeModel.widthForCover1+'rpx',
					'height': nodeModel.heightForCover1+'rpx',
					'borderRadius': nodeModel.borderRadiusForCover1 + 'rpx'
				}" :src="item.coverUrl" mode='aspectFill'></image>
			</view>
			<!-- style="border: #007AFF00 1rpx solid;" 不加这句话，内边距会占用盒子宽度 -->
			<view style="border: #007AFF00 1rpx solid;" :style="{
				'paddingTop': nodeModel.paddingTopForFlex2+'rpx',
				'paddingBottom': nodeModel.paddingBottomForFlex2+'rpx',
				'paddingLeft': nodeModel.paddingLeftForFlex2+'rpx',
				'paddingRight': nodeModel.paddingRightForFlex2+'rpx',
			}">
				<!-- 商品名称 -->
				<view class="limitLineNumOfOne" v-if="nodeModel.isShowForText1" :style="{
					'marginTop': nodeModel.marginTopForText1+'rpx',
					'color': nodeModel.colorForText1,
					'font-size': nodeModel.fontsizeForText1 + 'rpx',
					'font-weight': nodeModel.fontweightForText1,
				}">{{item.name}}</view>
				<!-- 原价 -->
				<view style="display: flex;flex-direction: row;align-items: center;" v-if="nodeModel.isShowForText2"
					:style="{
					'marginTop': nodeModel.marginTopForText2+'rpx'
					}">
					<view v-if="nodeModel.titleForText2" :style="{
						'color': nodeModel.colorForText2,
						'font-size': nodeModel.fontsizeForText2 + 'rpx',
						'font-weight': nodeModel.fontweightForText2,
						}">{{nodeModel.titleForText2}}</view>
					<view v-if="nodeModel.isShowForText2" :style="{
						'text-decoration': nodeModel.deleteLineForText2,
						'color': nodeModel.colorForText2,
						'font-size': nodeModel.fontsizeForText2 + 'rpx',
						'font-weight': nodeModel.fontweightForText2,
					}">¥{{item.sellingPrice}}</view>
				</view>
				<!-- 销售价格 -->
				<view style="display: flex;flex-direction: row;align-items: baseline;" :style="{
					'marginTop': nodeModel.marginTopForText3+'rpx',
				}">
					<view v-if="nodeModel.isShowForText3" :style="{
						'color': nodeModel.colorForText3,
						'font-size': item.activity==123?'30rpx' : nodeModel.fontsizeForText3 + 'rpx',
						'font-weight': nodeModel.fontweightForText3
					}">¥{{item.suggestSellingPrice}}</view>
					<!-- 销量 -->
					<view style="display: flex;flex-direction: row;align-items: center;margin-left: 12rpx;" v-if="nodeModel.isShowForText4">
						<view v-if="nodeModel.titleForText4" :style="{
						'color': nodeModel.colorForText4,
						'font-size': nodeModel.fontsizeForText4 + 'rpx',
						'font-weight': nodeModel.fontweightForText4
					}">{{nodeModel.titleForText4}}</view>
						<view v-if="nodeModel.isShowForText4" style="margin-left: 6rpx;" :style="{
							'color': nodeModel.colorForText4,
							'font-size': nodeModel.fontsizeForText4 + 'rpx',
							'font-weight': nodeModel.fontweightForText4
						}">{{item.sales}}</view>
					</view>
				</view>
			</view>
		</view>
</template>

<script>
	export default{
		name: 'jc-iteminfo-container',
		props: {
			nodeModel: {
				type: Object,
				default: {}
			},
			item: {
				type: Object,
				default: {}
			}
		},
		data() {
			return {
			}
		},
		methods:{}
	}
</script>

<style>
</style>
